[codex] document runtime target desired state#171
Conversation
Co-Authored-By: Codex <noreply@openai.com>
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
🤖 Codex PR ReviewPlease ensure a human reviewer checks this PR before merging. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 73e3d64b00
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| "scheduler": { | ||
| "type": "object", | ||
| "additionalProperties": false, | ||
| "properties": { |
There was a problem hiding this comment.
Require complete scheduler payloads in schema
When a target is validated only through schemas/runtime-target.schema.json, a present runtime_target.scheduler can omit timezone, main_time, probe_time, or precheck_time and still pass because this new object has no required list. The Python validator rejects the same payload (validate_runtime_target requires a non-empty timezone and all three time fields), so schema-based consumers can accept targets that later fail runtime_settings.py validate or platform parsing; add the scheduler fields to required to keep the shared schema consistent with the runtime contract.
Useful? React with 👍 / 👎.
| "main_time": { | ||
| "type": "string" | ||
| }, | ||
| "probe_time": { | ||
| "type": "string" | ||
| }, | ||
| "precheck_time": { | ||
| "type": "string" | ||
| } |
There was a problem hiding this comment.
Reject malformed scheduler times in the schema
For schema-only validation paths, these new scheduler time fields accept any string, so values such as "45" or "not a cron" pass the shared schema even though runtime_settings.validate_target rejects anything that is not exactly 2 time fields or 5 cron fields. Since schemas/ is documented as shared between Python and JS consumers, this can let an invalid schedule through a schema-based switch preview/apply flow and fail only later in the Python/platform validator; constrain these fields with the same shape that the runtime validator enforces.
Useful? React with 👍 / 👎.
Summary
Validation